import request from "@/utils/http.js";

export function getGroupList(params) {
    return request({
        method: "GET",
        url: "msg_pay/chat/group/list",
        params
    })
}

export function createGroup(data) {
    return request({
        method: "POST",
        url: "msg_pay/chat/group/create",
        data
    })
}

export function getGroupInfo(groupId) {
    return request({
        method: "GET",
        url: `msg_pay/chat/group/${groupId}`
    })
}

export function getGroupRequestList(params) {
    return request({
        method: "GET",
        url: `msg_pay/chat/group/request`,
        params
    })
}
export function requestJoinGroup(data) {
    return request({
        method: "POST",
        url: `msg_pay/chat/group/request`,
        data
    })
}
export function updateGroupRequest(data) {
    return request({
        method: "PUT",
        url: `msg_pay/chat/group/request`,
        data
    })
}
